package vip.sweet.biz.modular.order.service.impl;

import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import vip.sweet.biz.modular.order.entity.BizOrderItems;
import vip.sweet.biz.modular.order.mapper.BizOrderItemsMapper;
import vip.sweet.biz.modular.order.params.BizOrderItemsAddParams;
import vip.sweet.biz.modular.order.service.BizOrderItemsService;

/**
 * @author ASUS
 * @Date 2025/10/5 11:13
 * @Descripition
 */
@Service
public class BizOrderItemsServiceImpl extends ServiceImpl<BizOrderItemsMapper, BizOrderItems> implements BizOrderItemsService {
    @Override
    public boolean add(BizOrderItemsAddParams bizOrderItemsAddParams) {
        if (ObjectUtil.isNotEmpty(bizOrderItemsAddParams))
            return save(BeanUtil.toBean(bizOrderItemsAddParams, BizOrderItems.class));
        return false;
    }
}
